A magnetic random access memory (MRAM) element is a memory having a magnetic tunnel junction (MTJ), and includes two magnetic layers, and an insulating layer provided between the magnetic layers. The magnetic layers are formed of a metal such as Co and/or Fe.
In manufacturing the magnetic random access memory, etching is performed to transfer a mask pattern to the two magnetic layers and the insulating film. In the etching, a reaction product, which is less likely to vaporize, is generated, and the reaction product is deposited on the workpiece. The reaction product may cause various problems such as a leakage current of the MRAM element, and thus it is necessary to remove the reaction product.
A method for removing the reaction product is described in Patent Literature 1. In the method described in Patent Literature 1, first, an upper magnetic layer out of the two magnetic layers, that is, out of a lower magnetic layer and an upper magnetic layer is etched by a plasma of a processing gas that contains a halogen. Subsequently, a protective film is formed on a surface of the workpiece. Subsequently, the insulating layer is etched. Then, a reaction product is removed by a processing gas that contains PF3 gas.